import 'package:flutter/material.dart';

/// Utility class for fixed dimensions optimized for 1080x1920 resolution
class ResponsiveUtil {
  // Fixed resolution - 1080x1920
  static const double designWidth = 1080.0;
  static const double designHeight = 1920.0;
  
  // Fixed sizes without responsiveness
  static const double standardPadding = 20.0;
  static const double standardSpacing = 16.0;
  static const double standardBorderRadius = 12.0;
  static const double largerBorderRadius = 25.0;
  
  // We'll keep the isTablet method to maintain compatibility with existing code
  static bool isTablet(BuildContext context) {
    return false; // Always return false to use phone layout
  }
  
  static bool isLargeTablet(BuildContext context) {
    return false; // Always return false to use phone layout
  }
  
  /// Fixed widths (no scaling)
  static double scaleWidth(BuildContext context, double value) {
    return value; // Return the fixed value without scaling
  }
  
  /// Fixed heights (no scaling)
  static double scaleHeight(BuildContext context, double value) {
    return value; // Return the fixed value without scaling
  }
  
  /// Fixed padding
  static EdgeInsets getScaledPadding(
    BuildContext context, {
    double horizontal = 16.0, 
    double vertical = 16.0,
  }) {
    return EdgeInsets.symmetric(
      horizontal: horizontal,
      vertical: vertical,
    );
  }
  
  /// Fixed text styles
  static TextStyle getScaledTextStyle(
    BuildContext context, {
    required double fontSize,
    FontWeight fontWeight = FontWeight.normal,
    Color color = Colors.black,
    double? height,
    TextOverflow? overflow,
    bool softWrap = true,
  }) {
    return TextStyle(
      fontSize: fontSize,
      fontWeight: fontWeight,
      color: color,
      height: height ?? 1.2,
      overflow: overflow,
    );
  }
  
  /// Fixed sidebar width
  static double getSidebarWidth(BuildContext context) {
    return 280.0; // Fixed sidebar width
  }
  
  /// Fixed content width
  static double getContentMaxWidth(BuildContext context) {
    return 1000.0; // Fixed content width
  }
  
  /// Fixed spacing
  static double getSpacing(BuildContext context, double baseSpacing) {
    return baseSpacing; // Return the fixed value
  }
  
  /// Fixed border radius
  static double getBorderRadius(BuildContext context, {double base = 8.0}) {
    return base; // Return the fixed value
  }
  
  /// Fixed icon size
  static double getIconSize(BuildContext context, {double base = 24.0}) {
    return base; // Return the fixed value
  }
  
  /// Fixed bottom nav height
  static double getBottomNavHeight(BuildContext context) {
    return 60.0; // Fixed height
  }
  
  /// Fixed button width
  static double getButtonMinWidth(BuildContext context) {
    return 120.0; // Fixed width
  }
  
  /// Fixed button height
  static double getButtonMinHeight(BuildContext context) {
    return 50.0; // Fixed height
  }
  
  /// Fixed button padding
  static double getButtonHorizontalPadding(BuildContext context) {
    return 20.0; // Fixed padding
  }
  
  /// Fixed text style with balanced properties
  static TextStyle getBalancedTextStyle(
    BuildContext context, {
    required double fontSize,
    FontWeight fontWeight = FontWeight.normal,
    Color color = Colors.black,
    TextOverflow? overflow,
  }) {
    return TextStyle(
      fontSize: fontSize,
      fontWeight: fontWeight,
      color: color,
      height: 1.3, // Fixed height
      overflow: overflow,
    );
  }
} 